// 代理操作仅限于本地开发环境，上线就失效了
const { createProxyMiddleware } = require("http-proxy-middleware");


module.exports = (app) => {
    app.use(
        createProxyMiddleware('/api', {
            // target: "http://172.18.1.147:9000/",
            target: "http://10.1.10.36:18000/",
            changeOrigin: true,
            // pathRewrite:{'^/api1':''}
        }),
        createProxyMiddleware('/data', {
            // target: "http://172.18.1.147:9000/",
            target: "http://10.1.10.36:18000/",
            changeOrigin: true,
        })
    )
};